<template>
	<view class="padding bg-white">
		<u-parse :content="docInfo.docDetail"></u-parse>
	</view>
</template>

<script>

	import { docInfo } from '@/api/cms.js';
	export default {
		data() {
			return {
				id: 0,
				docInfo: {},
			}
		},
		
		onLoad(options) {
			this.id = options.id;
		},
		onShow() {
			this.getDocInfo();
		},
		methods: {
			getDocInfo() {
				docInfo({
					docId: this.id
				}).then(res => {
					let docInfo = res.data;
					this.docInfo = docInfo;
					uni.setNavigationBarTitle({
						title: docInfo.docTitle
					})
				})
			}
		}
	}
</script>

<style>

</style>
